package com.demo.demo3;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 转账案例业务层实现类
 */
@Service("accountService")
public class AccountServiceImpl implements AccountService {
    @Autowired
    private AccountDao accountDao;
    public void transfer(String out, String in, Double money) {
        accountDao.outMoney(out, money);
        // int i = 1 / 0;
        accountDao.inMoney(in, money);
    }
}
